﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace lab1
{
    class Book: IComparable<Book>
    {
        string id, name, publisher, price;
       
        public Book(String id, String name, String publisher, String price)
        {
            this.id = id;
            this.name = name;
            this.publisher = publisher;
            this.price = price;
        }
        public string Price
        {
            get { return price; }
            set { price = value; }
        }

        public string Publisher
        {
            get { return publisher; }
            set { publisher = value; }
        }

        public string Name
        {
            get { return name; }
            set { name = value; }
        }

        public string Id
        {
            get { return id; }
            
        }




        #region IComparable<Book> Members

        public int CompareTo(Book other)
        {
            return this.name.CompareTo(other.name);
        }

        #endregion
    }
}
